﻿@using SmartStore.PayPal.Models;
@using SmartStore.Web.Framework;
@model PayPalPlusConfigurationModel
@{
	Layout = "";
}

<div class="plugin-actions">
	<button type="submit" name="save" class="btn btn-warning" value="save">
		<i class="fa fa-check"></i>
		<span>@T("Admin.Common.Save")</span>
	</button>
</div>

<div class="plugin-configuration">
	<div>
		<div class="alert alert-info alert-dismissible">
			@Html.Raw(T("Plugins.Payments.PayPalPlus.AdminInstruction"))
			<button type="button" class="close" data-dismiss="alert">&times;</button>
		</div>
	</div>
	<div>
		<a href="https://www.paypal.de/paypal-plus" target="_blank">
			<img src="@Url.Content("~/Plugins/SmartStore.PayPal/Content/branding.png")" alt="PayPal" />
		</a>
	</div>
</div>

@{ Html.RenderAction("StoreScopeConfiguration", "Setting", new { area = "Admin" }); }

@Html.ValidationSummary(false)

@using (Html.BeginForm())
{
	@Html.HiddenFor(model => model.TransactMode)

    @Html.Partial("ApiConfiguration")

    <table class="adminContent">
		<tr class="adminSeparator">
			<td colspan="2">
				<div class="admin-config-group">
					<div class="title">
						@T("Common.Misc")
					</div>
				</div>
			</td>
		</tr>
		<tr>
			<td class="adminTitle">
				@Html.SmartLabelFor(model => model.ThirdPartyPaymentMethods)
			</td>
			<td class="adminData">
				@Html.SettingEditorFor(model => model.ThirdPartyPaymentMethods, @<div>
					@Html.EditorFor(model => model.ThirdPartyPaymentMethods, "SelectList", new { multiple = "multiple", data_tags = "true", selectOptions = Model.AvailableThirdPartyPaymentMethods })
				</div>)
				@Html.ValidationMessageFor(model => model.ThirdPartyPaymentMethods)
			</td>
		</tr>
		<tr>
			<td class="adminTitle">
				@Html.SmartLabelFor(model => model.DisplayPaymentMethodLogo)
			</td>
			<td class="adminData">
				@Html.SettingEditorFor(model => model.DisplayPaymentMethodLogo)
				@Html.ValidationMessageFor(model => model.DisplayPaymentMethodLogo)
			</td>
		</tr>
		<tr>
			<td class="adminTitle">
				@Html.SmartLabelFor(model => model.DisplayPaymentMethodDescription)
			</td>
			<td class="adminData">
				@Html.SettingEditorFor(model => model.DisplayPaymentMethodDescription)
				@Html.ValidationMessageFor(model => model.DisplayPaymentMethodDescription)
			</td>
		</tr>
		<tr>
			<td class="adminTitle">
				@Html.SmartLabelFor(model => model.AdditionalFee)
			</td>
			<td class="adminData">
				@Html.SettingEditorFor(model => model.AdditionalFee, null, new { postfix = Model.PrimaryStoreCurrencyCode })
				@Html.ValidationMessageFor(model => model.AdditionalFee)
			</td>
		</tr>
		<tr>
			<td class="adminTitle">
				@Html.SmartLabelFor(model => model.AdditionalFeePercentage)
			</td>
			<td class="adminData">
				@Html.SettingEditorFor(model => model.AdditionalFeePercentage)
				@Html.ValidationMessageFor(model => model.AdditionalFeePercentage)
			</td>
		</tr>
    </table>
}